* Encoding: windows-1252.
*****************************************************************************************************************.
* Data for the replication of RADIO PUBLIC SERVICE ANNOUNCEMENTS AND VOTER PARTICIPATION AMONG NATIVE AMERICANS:.
*	EVIDENCE FROM TWO FIELD EXPERIMENTS.
* Eline A. de Rooij and Donald P. Green.
* Political Behavior (POBE).
* Date: July 8, 2016.
*****************************************************************************************************************.

* The following analyses were carried out using IBM SPSS Statistics 23 for Windows (64-bit). 

* NAES 2004 data.
* downloaded from http://www.annenbergpublicpolicycenter.org/political-communication/naes/ on January 29 2010.

* download .sav file into personal folder and open file.
GET
  FILE='F:\My files\Koahnic2010\NAES2004\NAES2004.sav'.
** NOTE: insert correct link to folder between ' '. 

** NOTE: data excludes Alaska and Hawaii.


***********************************.
*** RECODES.
***********************************.

FREQUENCIES
  VARIABLES=cWA01 cWA02 cWA03 cWC01 cWC03 cWC05 cWF08.

RECODE cWA01 (2=0)  (1=1)  INTO  male .
RECODE cWA02 (998 thru 999=SYSMIS)  (ELSE=Copy)  INTO  age .
RECODE cWA03 (998 thru 999=SYSMIS)  (ELSE=Copy)  INTO  education .
RECODE cWC01 (998 thru 999=SYSMIS)  (ELSE=Copy)  INTO  hispanic .
RECODE cWC03 (998 thru 999=SYSMIS)  (ELSE=Copy)  INTO  race .
RECODE cWC03 (998 thru 999=SYSMIS)  (ELSE=Copy)  INTO  race2 .
RECODE cWC05 (sysmis=1)  (ELSE=Copy)  INTO  citizen .
execute.

crosstab hispanic by race.

DO IF (hispanic = 1) .
RECODE
  race  (1=6)  (2=6)  .
END IF .
EXECUTE .
RECODE
  race (1=2) (2=3) (3=5) (4=1) (5=6) (6=4) .
value labels race 1 'American Indian' 2 'White non-Hispanic' 3 'Black non-Hispanic' 4 'White or Black Hispanic' 5 'Asian' 6 'Other'.
execute. 
freq race.

DO IF (hispanic = 1) .
RECODE
  race2  (1=6)  (2=7)  .
END IF .
EXECUTE .
RECODE
  race2 (5=7)  (6=5) (7=6) .
value labels race2 1 'White non-Hispanic' 2 'Black non-Hispanic' 3 'Asian' 4 'American Indian' 5 'White Hispanic' 6 'Black Hispanic' 7 'Other'.
freq race2.

value labels education 1 'grade 8 or lower' 2 'some high school, no diploma' 3 'high school diploma or equivalent' 4 'technical or vocational school after high school' 5 'some college, no degree' 6 'associates or two-year college degree' 7 'four-year college degree' 8 'graduate or professional school, no degree' 9 'graduate or professional degree'.

freq male age education hispanic race race2 citizen .


***********************************.
*** WEIGHTS.
***********************************.
* data are not weighted, have to construct own weights, see p. 47 codebook (CdBkNRCS.pdf):.
** NAES04 / 2004 National Annenberg Election Survey, National Rolling Cross-Section Codebook. 
*** Produced by the Annenberg Public Policy Center, University of Pennsylvania. www.annenbergpublicpolicycenter.org. Copyright 2006. Release 1.1 (January 2008).

* first recode relevant variables to to census groupings.
** age.
recode age (18 thru 24 = 1) (25 thru 34 = 2) (35 thru 44 = 3) (45 thru 54 = 4) (55 thru 64 = 5) (65 thru highest = 6) into agegroup.
value labels agegroup 1 '18 to 24' 2 '25 to 34' 3 '35 to 44' 4 '45 to 54' 5 '55 to 64' 6 '65 and older'.
** education. 
recode education (1 thru 2 = 1) (3 =2) (4 thru 5 = 3) (6 thru 9 = 4) into edugroup.
value labels edugroup 1 'less than high school' 2 'high school graduate' 3 'some college' 4 'college graduate'.
** race. 
recode race2 (1=1) (2=2) (5 thru 6 =3) (3 4 7 = 4) into racegroup.
value labels racegroup 1 'White non-Hispanic' 2 'Black non-Hispanic' 3 'Hispanic' 4 'Other'. 
** region. 
recode cWF08 (1 thru 2 = 1) (3 thru 4 = 2) (5 thru 7 = 3) (8 thru 9 = 4) into region.
value labels region 1 'Northeast' 2 'Midwest' 3 'South' 4 'West'.
freq male agegroup edugroup racegroup region.

** population statistics, obtained from p. 47 NAES 2004 codebook.
** men: 47.9; woman: 52.0.
** '18 to 24' : 12.6; '25 to 34': 18.1; '35 to 44': 20.8; '45 to 54': 19; '55 to 64': 13.1; '65 and older': 16.3.
** 'less than high school': 15.6; 'high school graduate': 35.8; 'some college': 23.3; 'college graduate': 25.3.
** White non-Hispanic': 71.9; 'Black non-Hispanic': 10.7; 'Hispanic': 11.8 4 'Other': 5.5.
** 'Northeast': 19.4; 'Midwest': 23.1; 'South': 35.8; 'West': 21.6.

** w = 1/p; p = %sample/%population  (probability of being in sample); w = %population/%sample.
** multiply all weights.

IF (male = 1) w_gender = 47.9/44.7 .
IF (male = 0) w_gender = 52.0/55.3 .
VARIABLE LABELS w_gender 'weight for gender' .

IF (agegroup = 1) w_age = 12.6/7.7.
IF (agegroup = 2) w_age = 18.1/16.1. 
IF (agegroup = 3) w_age = 20.8/20.3.
IF (agegroup = 4) w_age = 19.0/21.6.
IF (agegroup = 5) w_age = 13.1/16.3.
IF (agegroup = 6) w_age = 16.3/17.9.
VARIABLE LABELS w_age 'weight for age' .

IF (edugroup = 1) w_edu = 15.6/7.4.
IF (edugroup = 2) w_edu = 35.8/26.0.
IF (edugroup = 3) w_edu = 23.3/20.4.
IF (edugroup = 4) w_edu = 25.3/46.3.
VARIABLE LABELS w_edu 'weight for education' .

IF (racegroup = 1) w_race = 71.9/79.9.
IF (racegroup = 2) w_race = 10.7/7.8.
IF (racegroup = 3) w_race = 11.8/5.6.
IF (racegroup = 4) w_race = 5.5/6.8.
VARIABLE LABELS w_race 'weight for race' .

IF (region = 1) w_region = 19.4/19.5.
IF (region = 2) w_region = 23.1/24.8.
IF (region = 3) w_region = 35.8/35.2.
IF (region = 4) w_region = 21.6/20.5.
VARIABLE LABELS w_region 'weight for region' .
EXECUTE .

COMPUTE weight = w_gender * w_age * w_edu * w_race * w_region .
VARIABLE LABELS weight 'weight for gender, age, education, race and region' .
EXECUTE .

* correct for household size.
** cWF01 total number of adults in household.

compute tot_weight = weight*cWF01.


**********************************************************************************.
** TABLE A.4 IN APPENDIX: Radio exposure, by race and ethnicity. 
*     (citizens 18 and older only).
**********************************************************************************.

freq cEA14 cEA15 .

RECODE cEA14 (998 thru 999=SYSMIS) (ELSE=Copy) INTO npr.
RECODE cEA15 (998 thru 999=SYSMIS) (ELSE=Copy)  INTO talkr.

** drop non-citizens.
USE ALL.
COMPUTE filter_$=(citizen  ~= 2).
VARIABLE LABELS filter_$ 'citizen  ~= 2 (FILTER)'.
VALUE LABELS filter_$ 0 'Not Selected' 1 'Selected'.
FORMATS filter_$ (f1.0).
FILTER BY filter_$.
EXECUTE.
freq citizen.

* obtain relevant Ns.
MEANS
  TABLES= npr talkr BY race
  /CELLS MEAN COUNT STDDEV MEDIAN  .

* weighted estimates of means days of national public radio and other talk radio.
weight by tot_weight.
MEANS
  TABLES= npr talkr BY race
  /CELLS MEAN COUNT STDDEV MEDIAN  .
weight off.

filter off.